/*
 * @Description  :
 * @Autor        : guoxi
 * @Date         : 2022-06-09 18:09:28
 * @LastEditors  : Please set LastEditors
 * @LastEditTime : 2022-07-29 09:11:38
 * @FilePath     : \rpms\src\api\document.ts
 */
import http from "../utils/http/service";

// 获取列表
export const getList = (data): any => {
  return http.post("/rdms-admin/sysDocument/documentList", data);
};
export const getProjectDocList = (data): any => {
  return http.post("/rdms-admin/sysDocument/project/documents", data);
};
export const getContractDocList = (data): any => {
  return http.post("/rdms-admin/sysDocument/contract/documents", data);
};
export const getOtherDocList = (data): any => {
  return http.post("/rdms-admin/sysDocument/other/documents", data);
};

// 附件列表
export const getFileList = (data): any => {
  return http.post("/rdms-admin/sysDocument/proDocList", data);
};

// 删除文档
export const onDelete = (data): any => {
  return http.post("/rdms-admin/sysDocument/delete", data);
};

// 更新
export const onSave = (data): any => {
  return http.post("/rdms-admin/sysDocument/update", data);
};

// 新建文档
export const onAdd = (data): any => {
  return http.post("/rdms-admin/sysDocument/add", data);
};

// 文档类型
export const postDictList = (data): any => {
  return http.post("/rdms-admin/sysDict/dictList", data);
};

// 查询文档详情
export const getDocumentInfo = (data): any => {
  return http.get(`/rdms-admin/sysDocument/info/${data.id}`);
};

// 查询文档下载
export const postDownloadList = (data): any => {
  return http.post(`/rdms-admin/sysDocument/docDowloadList`, data);
};

// 文档下载
export const postDownload = (data): any => {
  return http.post(`/rdms-admin/sysDocument/docZipDowload`, data);
};

// 获取项目列表数据
export const postProjectTree = (data): any => {
  return http.post("/rdms-admin/projectManage/projectTree", data);
};
// 论文
export const postPaperList = (data): any => {
  return http.post("/rdms-admin/scientific-paper/list", data);
};
export const addPaper = (data): any => {
  return http.post("/rdms-admin/scientific-paper/add", data);
};
export const updatePaper = (data): any => {
  return http.post("/rdms-admin/scientific-paper/update", data);
};

export const delPaper = (id): any => {
  return http.post("/rdms-admin/scientific-paper/delete/" + id);
};
export const getPaperById = (id): any => {
  return http.post("/rdms-admin/scientific-paper/detail/" + id);
};

//专著

export const postBookList = (data): any => {
  return http.post("/rdms-admin/scientific-book/list", data);
};
export const addBook = (data): any => {
  return http.post("/rdms-admin/scientific-book/add", data);
};
export const updateBook = (data): any => {
  return http.post("/rdms-admin/scientific-book/update", data);
};
export const delBook = (id): any => {
  return http.post("/rdms-admin/scientific-book/delete/" + id);
};
export const getBookById = (id): any => {
  return http.post("/rdms-admin/scientific-book/detail/" + id);
};
//标准

export const postStandarList = (data): any => {
  return http.post("/rdms-admin/scientific-standard/list", data);
};
export const addStandar = (data): any => {
  return http.post("/rdms-admin/scientific-standard/add", data);
};
export const updateStandar = (data): any => {
  return http.post("/rdms-admin/scientific-standard/update", data);
};
export const delStandar = (id): any => {
  return http.post("/rdms-admin/scientific-standard/delete/" + id);
};
export const getStandardById = (id): any => {
  return http.post("/rdms-admin/scientific-standard/detail/" + id);
};
//科技奖励/scientific-

export const postRewardsList = (data): any => {
  return http.post("/rdms-admin/scientific-rewards/list", data);
};
export const addRewards = (data): any => {
  return http.post("/rdms-admin/scientific-rewards/add", data);
};
export const updateRewards = (data): any => {
  return http.post("/rdms-admin/scientific-rewards/update", data);
};
export const delRewards = (id): any => {
  return http.post("/rdms-admin/scientific-rewards/delete/" + id);
};
export const getRewardsById = (id): any => {
  return http.post("/rdms-admin/scientific-rewards/detail/" + id);
};
//专利

export const postPatentList = (data): any => {
  return http.post("/rdms-admin/scientific-patent/list", data);
};
export const addPatent = (data): any => {
  return http.post("/rdms-admin/scientific-patent/add", data);
};
export const updatePatent = (data): any => {
  return http.post("/rdms-admin/scientific-patent/update", data);
};
export const delPatent = (id): any => {
  return http.post("/rdms-admin/scientific-patent/delete/" + id);
};
export const getPatentById = (id): any => {
  return http.post("/rdms-admin/scientific-patent/detail/" + id);
};
//软件著作

export const postSoftwareList = (data): any => {
  return http.post("/rdms-admin/RdScientificSoftware/list", data);
};
export const addSoftware = (data): any => {
  return http.post("/rdms-admin/RdScientificSoftware/add", data);
};
export const updateSoftware = (data): any => {
  return http.post("/rdms-admin/RdScientificSoftware/update", data);
};
export const delSoftware = (id): any => {
  return http.post("/rdms-admin/RdScientificSoftware/delete/" + id);
};
export const getSoftwareById = (id): any => {
  return http.post("/rdms-admin/RdScientificSoftware/detail/" + id);
};
//科技制度建设著作

export const postSystemList = (data): any => {
  return http.post("/rdms-admin/scientific-system/list", data);
};
export const addSystem = (data): any => {
  return http.post("/rdms-admin/scientific-system/add", data);
};
export const updateSystem = (data): any => {
  return http.post("/rdms-admin/scientific-system/update", data);
};
export const delSystem = (id): any => {
  return http.post("/rdms-admin/scientific-system/delete/" + id);
};
export const getSystemById = (id): any => {
  return http.post("/rdms-admin/scientific-system/detail/" + id);
};
// export const getSystemById = (id): any => {
//   return http.post("/rdms-admin/scientific-system/detail/" + id);
// };

//导出
